package com.ruoyi.depot.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Builder;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 修改预留量/锁定量 tb_local_inventory_reserved_log
 */
@Data
@TableName(value ="tb_local_inventory_reserved_log")
public class LocalInventoryReservedLog {
    private static final long serialVersionUID = 1L;

    @TableId(value = "inventory_reserved_log_id")
    private String inventoryReservedLogId;

    /**
     * 产品SKU
     */
    @Excel(name = "产品SKU")
    @TableField(value = "sku")
    private String sku;

    /**
     * 仓库ID
     */
    @TableField(value = "warehouse_id")
    private Long warehouseId;

    /**
     * 旧预留量/锁定量
     */
    @Excel(name = "旧预留量/锁定量")
    @TableField(value = "reserved_quantity_old")
    private BigDecimal reservedQuantityOld;

    /**
     * 新预留量/锁定量
     */
    @Excel(name = "新预留量/锁定量")
    @TableField(value = "reserved_quantity_new")
    private BigDecimal reservedQuantityNew;

    @Excel(name = "新预留量/锁定量")
    @TableField(value = "created_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createdTime;

    @Excel(name = "新预留量/锁定量")
    @TableField(value = "created_by")
    private String createdBy;

    @Excel(name = "差异")
    @TableField(exist = false)
    private BigDecimal diffQuantity;

    @Excel(name = "产品名称")
    @TableField(exist = false)
    private String productName;

    @Excel(name = "仓库名称")
    @TableField(exist = false)
    private String warehouseName;

}
